<template>
  <div style="height: 100%">
    <!-- <el-button type="primary" @click="handlePublish">发布</el-button>
    <el-button type="primary" @click="handleValidate">校验</el-button>-->
    <FGDesigner ref="FGDesigner" v-model="formConf" :enabled="true" />
  </div>
</template>

<script>
import { list, form, config } from "@/utils/drawingDefalut.js";
import FGDesigner from "@/package/FGDesigner";
export default {
  name: "create",
  components: {
    FGDesigner
  },

  data() {
    return {
      formConf: {},
      defaultConfig: config
      // formConf: JSON.stringify(drawingDefalut),
    };
  },

  methods: {
    handleValidate() {
      this.$refs.FGDesigner.validate((valid, message) => {
        console.log(valid, message);
        if (valid) {
        } else {
          this.$message.error(message);
        }
      });
    },
    handlePublish() {
      this.$refs.FGDesigner.submit(value => {
        console.log(value);
      });
    }
  }
};
</script>

<style lang="scss" scoped></style>
